package com.moon.cloud.common.request;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Builder;
import lombok.Data;

/**
 * 分页请求基类
 */
@Data
@Builder
@Schema(description = "分页请求")
public class PageRequest {

    /**
     * 当前页码
     */
    @Schema(description = "当前页码", defaultValue = "1", example = "1")
    protected Integer pageIndex;

    /**
     * 每页查询数量
     */
    @Schema(description = "每页查询数量", defaultValue = "10", example = "10")
    protected Integer pageSize;

    public PageRequest() {
    }

    public PageRequest(Integer pageIndex, Integer pageSize) {
        this.pageIndex = pageIndex;
        this.pageSize = pageSize;
    }

}
